package edu.scsu.csci.annotation.validator;

import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;


/**
 * @author Maqbool Khan
 * @since jdk 1.5
 * @see
 */
@Target( { ElementType.FIELD})
@Documented
@Retention(value = RetentionPolicy.RUNTIME)
public @/**
 * @viz.diagram AStringValidator.tpx
 */
interface AStringValidator {
	
	/**
	 * @return
	 */
	 boolean isNullAllowed() default true;
	
	/**
	 * @return
	 */
	 int maxLength();
	
	/**
	 * @return
	 */
	 int minLength() default 0;
	
	/**
	 * Valid values for the string object.
	 * 
	 * @return list
	 */
	 String[] validValues() default {};
	
	/**
	 * The error meessage to be used when validation fails.
	 * 
	 * @return
	 */
	 String errorMessage();
}
